﻿using System;
using System.Collections.Generic;

namespace ExtendedMvc.Common.EntityFramework {
	public interface ILogicalRepository<TEntity> : IBaseRepository<TEntity> where TEntity : ILogicalEntity, IBaseEntity {

		bool Exists(long id, bool includeDeleted = false);
		TEntity GetById(long id, bool includeDeleted = false);

		IEnumerable<TEntity> All(bool includeDeleted = false);
		IEnumerable<TEntity> Filter(Func<TEntity, bool> predicate, bool includeDeleted = false);

		long Count(Func<TEntity, bool> predicate = null, bool includeDeleted = false);
	}
}
